home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Tech Arsenal 1
/
Tech Arsenal (Arsenal Computer).ISO
/
tek-19
/
pkey12_1.zip
/
EE.LSP
< prev
next >
Wrap
Text File
|
1992-09-13
|
983b
|
34 lines
(defun ederr (s)
(if (/= s "Function cancelled")(princ (strcat "\nError: " s)))
(setq *error* oer ederr nil )(princ))
(setq oer *error* *error* ederr)
(princ "\nExternal Editor Program - Make sure editor is on path.")
(princ "\nDefault name for editor is EDIT.")
(setq ss (ssget))
(setq counter 0)
(setq tftemp "tempfil.xxx")
(prompt "Writing text...")
(setq txt(open tftemp "w"))
(while
(setq e (ssname ss counter))
(setq st (cdr (assoc 1 (entget e))))
(setq sp(cdr (assoc 10 (entget e))))
(setq sl(cdr (assoc 7 (entget e))))
(princ st txt)
(princ "\n" txt)
(setq counter (+ counter 1)))
(progn
(close txt)
(command "edit" tftemp)
(command "erase" ss "")
(setq sp(getpoint "\nNew startpoint for text: "))
(if (= sp nil)(ederr))
(setq txt(open tftemp "r"))
(setq dt(read-line txt))
(command "text" "s" sl sp "" dt)
(while
(/= dt nil)
(setq dt(read-line txt))
(command "text" "" dt))
(close txt)
(princ))